﻿@model ViewDataBusiness.ViewSetting
@{
    ViewBag.Title = Model.ViewTitle;

    ViewBag.jQuery = true;
    ViewBag.jQueryUI = true;
    ViewBag.Json = true;
    ViewBag.Flexigrid = true;
    ViewBag.Global = true;

    ViewBag.Css = "/Content/ViewSetting/Site.css";
    ViewBag.Js = "/Content/" + ViewContext.RouteData.Values["ViewForder"] + "/" + ViewContext.RouteData.Values["ViewName"] + ".js";
    
    Layout = "~/Views/_Template.cshtml";
}
<script type="text/javascript">var JsonOriginal = @Html.Raw(Model.JsonString);</script> 
<table id="MainTable" cellpadding="0" cellspacing="4" width="100%">
    <tr id="TitleTR"><td class="PageTitle"><div class="Title">@Model.ViewTitle > @ViewContext.RouteData.Values["KeyB"] ( @ViewContext.RouteData.Values["KeyA"] )</div></td></tr> 
    <tr id="SearchTR"><td class="Search TopTD"><button id="ButtonAddInput" title="手工录入方式添加产品（产品可重复）">添加产品</button><button id="ButtonAddSelect" title="搜索选择方式添加产品（产品不可重复）" style="margin-right:16px;">添加产品</button><button id="ButtonBack" style="margin-right:16px;">返回</button></td></tr>         
    <tr><td id="ListTD"></td></tr>    
    <tr id="PageTR"><td class="Page"></td></tr>
</table>
<table id="SelectTable" cellpadding="0" cellspacing="4" width="100%" style="display:none">
    <tr id="SelectTitleTR"><td class="PageTitle" colspan="3"><div class="Title">@Model.ViewTitle > @ViewContext.RouteData.Values["KeyB"] ( @ViewContext.RouteData.Values["KeyA"] ) > 选择添加产品</div></td></tr> 
    <tr><td valign="top" style="width:450px;">
        <table id="STable" cellpadding="0" cellspacing="0">
            <tr id="SelectSearchTR"><td class="Search TopTD"></td></tr>         
            <tr><td id="SelectListTD" style="padding:4px 0"></td></tr>    
            <tr id="SelectPageTR"><td class="Page"></td></tr>
        </table>
    </td>
    <td valign="top">
        <table id="CTable" cellpadding="0" cellspacing="0">
            <tr id="CheckSearchTR"><td class="Search TopTD"><button id="CheckSave">保存</button><button id="CheckBack" style="margin-right:16px;">返回</button></td></tr>         
            <tr><td id="CheckListTD" style="padding-top:4px"></td></tr>
        </table>
    </td></tr>
</table>
<div style="display:none" id="UpdateDialog" title="修改产品资料">
<input type="hidden" id="AutoID" />
<table class="DialogMianTable" id="UpdateTable" cellpadding="0" cellspacing="4" style="margin-top:8px;">
    <tr><td class="Unit"> 
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品货号</td><td class="Input"><input type="text" id="pd_id" readonly="readonly" style="width:80px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品名称</td><td class="Input"><input type="text" id="pd_cn_name" readonly="readonly" style="width:240px" /></td></tr></table></div>
        <div class="Clear"></div>                                                                                                                                                          
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品单位</td><td class="Input"><input type="text" id="uom" readonly="readonly" style="width:80px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品规格</td><td class="Input"><input type="text" id="pd_cn_spec" readonly="readonly" style="width:240px" /></td></tr></table></div>
        <div class="Clear"></div>                                                                                                                                                                                                                                  
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">对方编码</td><td class="Input"><input type="text" class="Required" id="ct_pd_id" maxlength="50" style="width:395px" /></td></tr></table></div>
    </td></tr>
</table>
</div>
<div style="display:none" id="AddDialog" title="添加产品">
<table class="DialogMianTable" cellpadding="0" cellspacing="4" style="margin-top:8px;"><tbody id="AddTable"></tbody></table>
</div>
<div id="ItemHTML" style="display:none">
<input class="AutoComplete" type="hidden" name="AutoID" />
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">货号</td><td class="Input"><input class="Select AutoComplete" lang="筛选产品货号" type="text" name="pd_id" title="筛选货号，请输入两个或以上字符。" style="width:80px" /></td></tr></table></div>
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">名称</td><td class="Input"><input class="Select AutoComplete" lang="筛选产品名称" type="text" name="pd_cn_name" title="筛选名称，请输入两个或以上字符。" style="width:150px" /></td></tr></table></div>
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">规格</td><td class="Input"><input class="Select AutoComplete" lang="筛选产品型号" type="text" name="pd_cn_spec" title="筛选规格，请输入两个或以上字符。" style="width:150px" /></td></tr></table></div>     
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">单位</td><td class="Input"><input class="AutoComplete" type="text" name="uom" readonly="readonly" style="width:50px" /></td></tr></table></div>                                    
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">对方编码</td><td class="Input"><input type="text" readonly="readonly" name="ct_pd_id" maxlength="50" style="width:80px" /></td></tr></table></div>        
<div class="AIcon"><div class="Icon" onclick="DeleteItem(this);" style="visibility:hidden"><div class="ui-state-default ui-corner-all" onmouseover="$(this).addClass('ui-state-hover');" onmouseout="$(this).removeClass('ui-state-hover');"><span class="ui-icon ui-icon-close"></span></div></div></div>
</div>